import request from './request'

// 获取当前用户的健康记录
export const getCurrentHealthRecordApi = () => request.get('/health-records/current')

// 创建健康记录
export const createHealthRecordApi = data => request.post('/health-records', data)
export const addCheckApi = data => request.post('/health-records', data)

// 更新健康记录
export const updateHealthRecordApi = (id, data) => request.put(`/health-records/${id}`, data)

// 删除健康记录
export const deleteHealthRecordApi = id => request.delete(`/health-records/${id}`)

// 获取指定用户的健康记录列表
export const getUserHealthRecordsApi = userId => request.get(`/health-records/user/${userId}`) 